<?php
/* @var $this NdkPremiNonController */
/* @var $model NdkPremiNon */


$this->breadcrumbs=array(
	'Ndk Premi Nons'=>array('index'),
	'Manage',
);

$this->menu=array(
	array('label'=>'List NdkPremiNon', 'url'=>array('index')),
	array('label'=>'Create NdkPremiNon', 'url'=>array('create')),
);

Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
	$('.search-form').toggle();
	return false;
});
$('.search-form form').submit(function(){
	$('#ndk-premi-non-grid').yiiGridView('update', {
		data: $(this).serialize()
	});
	return false;
});
");
?>

<h1>Manajemen Non Premi</h1>

<a href="<?php echo Yii::app()->createUrl('ndkPremiNon/create'); ?>" class="btn btn-sm btn-primary">Input</a><br /><br />

<?php //echo CHtml::link('Advanced Search','#',array('class'=>'search-button btn')); ?>
<div class="search-form" style="display:none">
<?php $this->renderPartial('_search',array(
	'model'=>$model,
)); ?>
</div><!-- search-form -->

<?php $this->widget('bootstrap.widgets.TbGridView',array(
	'id'=>'ndk-premi-non-grid',
	'dataProvider'=>$model->search(),
	'filter'=>$model,
	'columns'=>array(
		'no_invoice',
		/*
		'nama_client',
		'mst_client_id',
		'due_date',
		'nominal',
		'keterangan',
		'mst_coa_id_debet',
		'mst_coa_id_kredit',
		*/
		array(
                'class'=>'bootstrap.widgets.TBButtonColumn',
               'template' => '{lihat}{print}',
               'buttons' => array(
               				'lihat' => array(
                              'url' => 'Yii::app()->createUrl("ndkPremiNon/view", array("id"=>$data->id))',
								'options'=>array(
								'class'=>'btn btn-small view'
								)
                            ),

                            'print' => array(
                              'url' => 'Yii::app()->createUrl("ndkPremiNon/cetak", array("id"=>$data->id))',
                              'options'=>array(
                                   'class'=>'btn btn-small print'
                                   ),
                            ),

               ),
            'htmlOptions'=>array('style'=>'width: 250px'),
           ),
	),
)); ?>